import request from "@/api/request";
import { type Result, type DeepRequired } from "../../interface";
import { type AxiosRequestConfig } from "axios";

/**
 * 校验文件md5
 * /upload/check
 */
export function getUploadCheck(params: GetUploadCheckParams, config?: AxiosRequestConfig) {
    const paramsInput = {
        md5: params.md5,
    };
    return request.get<DeepRequired<Result>>(`/upload/check`, {
        params: paramsInput,
        ...config,
    });
}

export interface GetUploadCheckParams {
    md5: string;
}
